//
//  BkYunfeeView.m
//  TuDianEducation
//
//  Created by lixinkeji on 2021/1/25.
//  Copyright © 2021 zhangbenchao. All rights reserved.
//

#import "BkYunfeeView.h"
@interface BkYunfeeView()
@property (nonatomic,strong) UIView *yunView;

@end

@implementation BkYunfeeView
- (instancetype)init
{
    self = [super init];
    if (self) {
        self.backgroundColor = kSubBacColor;
        self.frame = CGRectMake(0, 0, TSScreenWidth, TSScaleW(60));
        [self addSubview:self.yunView];
        [self.yunView addSubview:self.yunfeeLabel];
    }
    return self;
}

-(UIView *)yunView{
    if (!_yunView) {
        _yunView = [[UIView alloc]initWithFrame:CGRectMake(0, 0, TSScreenWidth, TSScaleW(45))];
        _yunView.backgroundColor = kWhiteColor;
        UILabel *nameLabel = [TSWLTools allocLabel:@"运费" font:systemFont(TSScaleW(13)) textColor:kSubTxtColor frame:CGRectMake(TSScaleW(12), 0, TSScaleW(200), _yunView.height) textAlignment:(NSTextAlignmentLeft)];
        [_yunView addSubview:nameLabel];
        
    }
    return _yunView;
}

-(UILabel *)yunfeeLabel{
    if (!_yunfeeLabel) {
        _yunfeeLabel = [TSWLTools allocLabel:@"免运费" font:systemFont(TSScaleW(13)) textColor:kGreenColor frame:CGRectMake(TSScaleW(20), 0, _yunView.width - TSScaleW(32), _yunView.height) textAlignment:(NSTextAlignmentRight)];
    }
    return _yunfeeLabel;
}

@end
